3.29 \(\int \frac{(3-x+2 x^2)^2}{(2+3 x+5 x^2)^4} \, dx\)

Optimal. Leaf size=85 \[ \frac{16688 (10 x+3)}{148955 \left (5 x^2+3 x+2\right )}+\frac{11 (12060 x+4579)}{120125 \left (5 x^2+3 x+2\right )^2}+\frac{121 (69 x+61)}{11625 \left (5 x^2+3 x+2\right )^3}+\frac{66752 \tan ^{-1}\left (\frac{10 x+3}{\sqrt{31}}\right )}{29791 \sqrt{31}} \]

[Out]

(121*(61 + 69*x))/(11625*(2 + 3*x + 5*x^2)^3) + (11*(4579 + 12060*x))/(120125*(2 + 3*x + 5*x^2)^2) + (16688*(3
 + 10*x))/(148955*(2 + 3*x + 5*x^2)) + (66752*ArcTan[(3 + 10*x)/Sqrt[31]])/(29791*Sqrt[31])

________________________________________________________________________________________

Rubi [A]  time = 0.0633293, antiderivative size = 85, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 5, integrand size = 25, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.2, Rules used = {1660, 12, 614, 618, 204} \[ \frac{16688 (10 x+3)}{148955 \left (5 x^2+3 x+2\right )}+\frac{11 (12060 x+4579)}{120125 \left (5 x^2+3 x+2\right )^2}+\frac{121 (69 x+61)}{11625 \left (5 x^2+3 x+2\right )^3}+\frac{66752 \tan ^{-1}\left (\frac{10 x+3}{\sqrt{31}}\right )}{29791 \sqrt{31}} \]

Antiderivative was successfully verified.

[In]

Int[(3 - x + 2*x^2)^2/(2 + 3*x + 5*x^2)^4,x]

[Out]

(121*(61 + 69*x))/(11625*(2 + 3*x + 5*x^2)^3) + (11*(4579 + 12060*x))/(120125*(2 + 3*x + 5*x^2)^2) + (16688*(3
 + 10*x))/(148955*(2 + 3*x + 5*x^2)) + (66752*ArcTan[(3 + 10*x)/Sqrt[31]])/(29791*Sqrt[31])

Rule 1660

Int[(Pq_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = PolynomialQuotient[Pq, a + b*x + c*
x^2, x], f = Coeff[PolynomialRemainder[Pq, a + b*x + c*x^2, x], x, 0], g = Coeff[PolynomialRemainder[Pq, a + b
*x + c*x^2, x], x, 1]}, Simp[((b*f - 2*a*g + (2*c*f - b*g)*x)*(a + b*x + c*x^2)^(p + 1))/((p + 1)*(b^2 - 4*a*c
)), x] + Dist[1/((p + 1)*(b^2 - 4*a*c)), Int[(a + b*x + c*x^2)^(p + 1)*ExpandToSum[(p + 1)*(b^2 - 4*a*c)*Q - (
2*p + 3)*(2*c*f - b*g), x], x], x]] /; FreeQ[{a, b, c}, x] && PolyQ[Pq, x] && NeQ[b^2 - 4*a*c, 0] && LtQ[p, -1
]

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 614

Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Simp[((b + 2*c*x)*(a + b*x + c*x^2)^(p + 1))/((p +
1)*(b^2 - 4*a*c)), x] - Dist[(2*c*(2*p + 3))/((p + 1)*(b^2 - 4*a*c)), Int[(a + b*x + c*x^2)^(p + 1), x], x] /;
 FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*a*c, 0] && LtQ[p, -1] && NeQ[p, -3/2] && IntegerQ[4*p]

Rule 618

Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> Dist[-2, Subst[Int[1/Simp[b^2 - 4*a*c - x^2, x], x]
, x, b + 2*c*x], x] /; FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*a*c, 0]

Rule 204

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> -Simp[ArcTan[(Rt[-b, 2]*x)/Rt[-a, 2]]/(Rt[-a, 2]*Rt[-b, 2]), x] /
; FreeQ[{a, b}, x] && PosQ[a/b] && (LtQ[a, 0] || LtQ[b, 0])

Rubi steps

\begin{align*} \int \frac{\left (3-x+2 x^2\right )^2}{\left (2+3 x+5 x^2\right )^4} \, dx &=\frac{121 (61+69 x)}{11625 \left (2+3 x+5 x^2\right )^3}+\frac{1}{93} \int \frac{\frac{77178}{125}-\frac{2976 x}{25}+\frac{372 x^2}{5}}{\left (2+3 x+5 x^2\right )^3} \, dx\\ &=\frac{121 (61+69 x)}{11625 \left (2+3 x+5 x^2\right )^3}+\frac{11 (4579+12060 x)}{120125 \left (2+3 x+5 x^2\right )^2}+\frac{\int \frac{100128}{5 \left (2+3 x+5 x^2\right )^2} \, dx}{5766}\\ &=\frac{121 (61+69 x)}{11625 \left (2+3 x+5 x^2\right )^3}+\frac{11 (4579+12060 x)}{120125 \left (2+3 x+5 x^2\right )^2}+\frac{16688 \int \frac{1}{\left (2+3 x+5 x^2\right )^2} \, dx}{4805}\\ &=\frac{121 (61+69 x)}{11625 \left (2+3 x+5 x^2\right )^3}+\frac{11 (4579+12060 x)}{120125 \left (2+3 x+5 x^2\right )^2}+\frac{16688 (3+10 x)}{148955 \left (2+3 x+5 x^2\right )}+\frac{33376 \int \frac{1}{2+3 x+5 x^2} \, dx}{29791}\\ &=\frac{121 (61+69 x)}{11625 \left (2+3 x+5 x^2\right )^3}+\frac{11 (4579+12060 x)}{120125 \left (2+3 x+5 x^2\right )^2}+\frac{16688 (3+10 x)}{148955 \left (2+3 x+5 x^2\right )}-\frac{66752 \operatorname{Subst}\left (\int \frac{1}{-31-x^2} \, dx,x,3+10 x\right )}{29791}\\ &=\frac{121 (61+69 x)}{11625 \left (2+3 x+5 x^2\right )^3}+\frac{11 (4579+12060 x)}{120125 \left (2+3 x+5 x^2\right )^2}+\frac{16688 (3+10 x)}{148955 \left (2+3 x+5 x^2\right )}+\frac{66752 \tan ^{-1}\left (\frac{3+10 x}{\sqrt{31}}\right )}{29791 \sqrt{31}}\\ \end{align*}

Mathematica [A]  time = 0.0449281, size = 63, normalized size = 0.74 \[ \frac{12516000 x^5+18774000 x^4+21491796 x^3+12780597 x^2+5674908 x+1259239}{446865 \left (5 x^2+3 x+2\right )^3}+\frac{66752 \tan ^{-1}\left (\frac{10 x+3}{\sqrt{31}}\right )}{29791 \sqrt{31}} \]

Antiderivative was successfully verified.

[In]

Integrate[(3 - x + 2*x^2)^2/(2 + 3*x + 5*x^2)^4,x]

[Out]

(1259239 + 5674908*x + 12780597*x^2 + 21491796*x^3 + 18774000*x^4 + 12516000*x^5)/(446865*(2 + 3*x + 5*x^2)^3)
 + (66752*ArcTan[(3 + 10*x)/Sqrt[31]])/(29791*Sqrt[31])

________________________________________________________________________________________

Maple [A]  time = 0.05, size = 57, normalized size = 0.7 \begin{align*} 125\,{\frac{1}{ \left ( 5\,{x}^{2}+3\,x+2 \right ) ^{3}} \left ({\frac{33376\,{x}^{5}}{148955}}+{\frac{50064\,{x}^{4}}{148955}}+{\frac{7163932\,{x}^{3}}{18619375}}+{\frac{4260199\,{x}^{2}}{18619375}}+{\frac{1891636\,x}{18619375}}+{\frac{1259239}{55858125}} \right ) }+{\frac{66752\,\sqrt{31}}{923521}\arctan \left ({\frac{ \left ( 3+10\,x \right ) \sqrt{31}}{31}} \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((2*x^2-x+3)^2/(5*x^2+3*x+2)^4,x)

[Out]

125*(33376/148955*x^5+50064/148955*x^4+7163932/18619375*x^3+4260199/18619375*x^2+1891636/18619375*x+1259239/55
858125)/(5*x^2+3*x+2)^3+66752/923521*arctan(1/31*(3+10*x)*31^(1/2))*31^(1/2)

________________________________________________________________________________________

Maxima [A]  time = 1.44632, size = 103, normalized size = 1.21 \begin{align*} \frac{66752}{923521} \, \sqrt{31} \arctan \left (\frac{1}{31} \, \sqrt{31}{\left (10 \, x + 3\right )}\right ) + \frac{12516000 \, x^{5} + 18774000 \, x^{4} + 21491796 \, x^{3} + 12780597 \, x^{2} + 5674908 \, x + 1259239}{446865 \,{\left (125 \, x^{6} + 225 \, x^{5} + 285 \, x^{4} + 207 \, x^{3} + 114 \, x^{2} + 36 \, x + 8\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2-x+3)^2/(5*x^2+3*x+2)^4,x, algorithm="maxima")

[Out]

66752/923521*sqrt(31)*arctan(1/31*sqrt(31)*(10*x + 3)) + 1/446865*(12516000*x^5 + 18774000*x^4 + 21491796*x^3
+ 12780597*x^2 + 5674908*x + 1259239)/(125*x^6 + 225*x^5 + 285*x^4 + 207*x^3 + 114*x^2 + 36*x + 8)

________________________________________________________________________________________

Fricas [A]  time = 0.963056, size = 371, normalized size = 4.36 \begin{align*} \frac{387996000 \, x^{5} + 581994000 \, x^{4} + 666245676 \, x^{3} + 1001280 \, \sqrt{31}{\left (125 \, x^{6} + 225 \, x^{5} + 285 \, x^{4} + 207 \, x^{3} + 114 \, x^{2} + 36 \, x + 8\right )} \arctan \left (\frac{1}{31} \, \sqrt{31}{\left (10 \, x + 3\right )}\right ) + 396198507 \, x^{2} + 175922148 \, x + 39036409}{13852815 \,{\left (125 \, x^{6} + 225 \, x^{5} + 285 \, x^{4} + 207 \, x^{3} + 114 \, x^{2} + 36 \, x + 8\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2-x+3)^2/(5*x^2+3*x+2)^4,x, algorithm="fricas")

[Out]

1/13852815*(387996000*x^5 + 581994000*x^4 + 666245676*x^3 + 1001280*sqrt(31)*(125*x^6 + 225*x^5 + 285*x^4 + 20
7*x^3 + 114*x^2 + 36*x + 8)*arctan(1/31*sqrt(31)*(10*x + 3)) + 396198507*x^2 + 175922148*x + 39036409)/(125*x^
6 + 225*x^5 + 285*x^4 + 207*x^3 + 114*x^2 + 36*x + 8)

________________________________________________________________________________________

Sympy [A]  time = 0.251072, size = 83, normalized size = 0.98 \begin{align*} \frac{12516000 x^{5} + 18774000 x^{4} + 21491796 x^{3} + 12780597 x^{2} + 5674908 x + 1259239}{55858125 x^{6} + 100544625 x^{5} + 127356525 x^{4} + 92501055 x^{3} + 50942610 x^{2} + 16087140 x + 3574920} + \frac{66752 \sqrt{31} \operatorname{atan}{\left (\frac{10 \sqrt{31} x}{31} + \frac{3 \sqrt{31}}{31} \right )}}{923521} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x**2-x+3)**2/(5*x**2+3*x+2)**4,x)

[Out]

(12516000*x**5 + 18774000*x**4 + 21491796*x**3 + 12780597*x**2 + 5674908*x + 1259239)/(55858125*x**6 + 1005446
25*x**5 + 127356525*x**4 + 92501055*x**3 + 50942610*x**2 + 16087140*x + 3574920) + 66752*sqrt(31)*atan(10*sqrt
(31)*x/31 + 3*sqrt(31)/31)/923521

________________________________________________________________________________________

Giac [A]  time = 1.18208, size = 76, normalized size = 0.89 \begin{align*} \frac{66752}{923521} \, \sqrt{31} \arctan \left (\frac{1}{31} \, \sqrt{31}{\left (10 \, x + 3\right )}\right ) + \frac{12516000 \, x^{5} + 18774000 \, x^{4} + 21491796 \, x^{3} + 12780597 \, x^{2} + 5674908 \, x + 1259239}{446865 \,{\left (5 \, x^{2} + 3 \, x + 2\right )}^{3}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2-x+3)^2/(5*x^2+3*x+2)^4,x, algorithm="giac")

[Out]

66752/923521*sqrt(31)*arctan(1/31*sqrt(31)*(10*x + 3)) + 1/446865*(12516000*x^5 + 18774000*x^4 + 21491796*x^3
+ 12780597*x^2 + 5674908*x + 1259239)/(5*x^2 + 3*x + 2)^3